<template>
    <view :style="themeColor">
        <view class="page" >
    <view class="flex flex-wrap align-center justify-between benben-position-layout flex packageSelect_flex_0"    :style="{height:(88+StatusBarRpx)+'rpx',paddingTop:StatusBarRpx+'rpx', }">
            <view   class='flex flex-wrap align-center packageSelect_fd0_0'   @tap="handleJumpDiy" data-type="redirectTo" :data-url="`/pages/wd/settlementMerchant/settlementMerchant`"   >
        <image class='packageSelect_fd0_0_c0'  mode="aspectFit"  :src='STATIC_URL+"234.png"'></image>
</view>
<text class='packageSelect_fd0_1'  >选择套餐</text>
    <view   class='flex flex-wrap align-center packageSelect_fd0_0'      >
        </view>

        </view>
<view :style="{height: (88+StatusBarRpx)+'rpx'}"  ></view>
<!---flex布局flex布局开始-->
 <view class="flex flex-direction align-stretch benben-flex-layout"    >
        <text class='packageSelect_fd1_0'  >店铺信息</text>
    <template v-for = '(item,key0) in dataMessage'>
    <view   class='flex flex-direction flex-wrap align-stretch packageSelect_fd1_1' :style="{'border':`${ item.name==shopMessage.store_level  ?  '1px solid green':''}`}"  @tap="clickGetIdFunc(item.aid)"    :key='key0'>
            <view   class='flex flex-wrap align-center justify-between packageSelect_fd1_1_c0'      >
        <text class='packageSelect_fd1_1_c0_c0'  >{{item.name}}</text>
    <view   class='flex flex-wrap align-center packageSelect_fd1_1_c0_c1'      >
        <text class='packageSelect_fd1_1_c0_c0'  >￥</text>
<text class='packageSelect_fd1_1_c0_c0'  >{{item.money}}</text>
<text class='packageSelect_fd1_1_c0_c0'  >/</text>
<text class='packageSelect_fd1_1_c0_c0'  >年</text>
</view>
</view>
    <view   class='flex flex-wrap align-center justify-between packageSelect_fd1_1_c0'      >
        <text class='packageSelect_fd1_1_c1_c0'  >最大商品添加数量</text>
    <view   class='flex flex-wrap align-center'      >
        <text class='packageSelect_fd1_1_c1_c1_c0'  >{{item.goods_num}}</text>
<text class='packageSelect_fd1_1_c1_c1_c0'  >个</text>
</view>
</view>
    <view   class='flex flex-wrap align-center justify-between packageSelect_fd1_1_c2'      >
        <text class='packageSelect_fd1_1_c1_c0'  >平台抽成比例</text>
    <view   class='flex flex-wrap align-center'      >
        <text class='packageSelect_fd1_1_c1_c1_c0'  >{{item.merchant_ratio}}</text>
<text class='packageSelect_fd1_1_c1_c1_c0'  >%</text>
</view>
</view>
</view>
    </template>
    
</view>
        
<!---flex布局flex布局结束-->
    
    
        </view>
    </view>
</template>
<script>
    import {validate} from '@/common/utils/validate.js'
    
    export default {
        components:{},
        
        
        data(){
			return {"dataMessage":[],"dataDetails":{"storejoinin_aid":""},"name":"","id":"","shopMessage":{"aid":"","member_id":"","member_account":"","member_name":"","person":"","idcard_no":"","province_idc":"","province_name":"","city_id":"","city_name":"","district_id":"","district_name":"","address":"","store_province_id":"","store_province_name":"","store_city_id":"","store_city_name":"","store_district_id":"","store_district_name":"","store_address":"","contacts_name":"","contacts_phone":"","idcard_front":"","idcard_reverse":"","store_name":"","store_logo":"","business_licence":"","joinin_state":"","joinin_message":"","range":"","reason":"","merchant_ratio":"","apply_type":"","company_name":"","company_province_id":"","company_city_id":"","company_district_id":"","company_address":"","credit_code":"","store_level":"","main_industry":"","stay_time":"","pay_img":"","pay_remarks":"","pay_money":"","pay_time":"","run_type":"","expiration_time":"","store_backdrop":"","service_phone":"","store_introduce":"","workday":"","business_hours":"","enter_money":"","qualification_certificate":"","create_time":"","true_name":"","account_id":"","qrcode":"","bank_branch":"","bank_address":"","company_address_id":"","account_type":"","account_name":"","run_type_id":"","stay_time_id":"","main_industry_id":"","business_hours_start":"","business_hours_end":"","workday_id":""},"checkId":"","dataBack":{"storejoinin_aid":""}};
		},
		computed:{
            themeColor() {
              return this.$store.getters.themeColor
            },
            
		},
		watch:{},
		onLoad(options){
            this.queryMessageFunc()
this.getMessageShopFunc()
		},
        onUnload() {
                
        },
		onReady(){
            
		},
		onShow(){
            
		},
		onHide(){
            
		},
		onResize(){
            
		},
		onPullDownRefresh(){
            
		},
		onReachBottom(e){
            
		},
		onPageScroll(e){
            
		},
		methods:{
                            //商家入驻-获取商家入驻店铺套餐
                async queryMessageFunc(){
                        //请求方法
    //数据验证
    
  let datadataMessage = await this.$api.get(global.apiUrls.post62bd8617812eb, {
    list_rows:'15'
  });
  
  if (datadataMessage.data.code != 1) {
    this.$message.info(datadataMessage.data.msg);
    return
  } 
  let infodataMessage = datadataMessage.data;
  this.dataMessage = infodataMessage.data
  
                },
                //提交套餐
                async SubmitPackageFunc(){
                        //请求方法
    //数据验证
    
  let datadataBack = await this.$api.post(global.apiUrls.post62bd88b779464, {
    store_level:this.checkId
  });
  
  if (datadataBack.data.code != 1) {
    this.$message.info(datadataBack.data.msg);
    return
  } 
  let infodataBack = datadataBack.data;
  this.dataBack = infodataBack.data
  
    this.$urouter.redirectTo(`/pages/wd/informationAuthentication/informationAuthentication?name=${this.shopMessage.store_level}`);
                },
                //获取店铺信息
                async getMessageShopFunc(){
                    //获取店铺信息

        //请求方法
        //数据验证
        let datashopMessage = await this.$api.get(global.apiUrls.post62be7019e6ae4, {
        });
        // if (datashopMessage.data.code != 1) {
        //   this.$message.info(datashopMessage.data.msg);
        //   return
        // }
        let infoshopMessage = datashopMessage.data;
        this.shopMessage = infoshopMessage.data

                },
                //点击获取id
                 clickGetIdFunc(id){
                       this.checkId = id;
                    this.SubmitPackageFunc()
                }
		}
    };
</script> 
<style lang="scss" scoped>
           .page{
            width: 100vw;
            overflow-x: hidden;
            min-height: calc(100vh - var(--window-bottom));
            background:#F8F8F8;background-size: 100% auto;
        }
    .packageSelect_flex_0{
        background:#fff;width:750rpx;height:88rpx;overflow:hidden;z-index:10;top:0rpx;background-size:100% auto !important;
    }
    .packageSelect_fd0_1{
        color:#333333;font-size:36rpx;font-weight:500;line-height:50rpx;
    }
    .packageSelect_fd0_0_c0{
        width:20rpx;height:36rpx;border-radius:0rpx 0rpx 0rpx 0rpx;margin:0rpx 0rpx 0rpx 32rpx;
    }
    .packageSelect_fd0_0{
        width:100rpx;height:88rpx;
    }
    .packageSelect_fd1_1_c2{
        padding:32rpx 0rpx 32rpx 0rpx;
    }
    .packageSelect_fd1_1_c1_c1_c0{
        color:#333333;font-size:28rpx;font-weight:500;line-height:40rpx;
    }
    .packageSelect_fd1_1_c1_c0{
        color:#333;font-size:28rpx;font-weight:500;line-height:40rpx;
    }
    .packageSelect_fd1_1_c0_c1{
        background:#EEF5F1;border-radius:28rpx 28rpx 28rpx 28rpx;padding:9rpx 21rpx 7rpx 21rpx;
    }
    .packageSelect_fd1_1_c0_c0{
        color:var(--benbenFontColor5);font-size:28rpx;font-weight:500;line-height:40rpx;
    }
    .packageSelect_fd1_1_c0{
        border-bottom:1px solid #eee;padding:32rpx 0rpx 32rpx 0rpx;
    }
    .packageSelect_fd1_1{
        background:#FFFFFF;border-radius:16rpx 16rpx 16rpx 16rpx;margin:24rpx 32rpx 0rpx 32rpx;padding:0rpx 32rpx 0rpx 32rpx;
    }
    .packageSelect_fd1_0{
        margin:32rpx 32rpx 0rpx 32rpx;font-size:32rpx;font-weight:600;color:#333;
    }
</style>